package com.algo.pattern.composite;

public class CompositeTest {

    public static void main(String[] args) throws Exception {
        DirNode node = new DirNode("c");

        DirNode systemNode = new DirNode("system");
        systemNode.addChild(new FileNode("aa.txt"));

        node.addChild(systemNode);
        node.addChild(new FileNode("a.txt"));

        node.println();
    }

}
